package com.sprouting.ops.model;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.sprouting.ops.annotations.invoke.CheckIsNullOrEmpty;
import com.sprouting.ops.annotations.invoke.CheckLength;
import com.sprouting.ops.annotations.invoke.CheckNotNull;
import com.sprouting.ops.interfaces.AddGroup;
import com.sprouting.ops.interfaces.UpdGroup;
import lombok.Data;

/**
 * 知识库评论;(OpsKnowledgeComment)(OPS_KNOWLEDGE_COMMENT) 表实体类
 *
 * @author ：lx（长沙麓谷）
 * @date 创建时间：2025-08-21 22:45:33
 */
@Data
@TableName("ops_knowledge_comment")
public class OpsKnowledgeComment extends BaseModel {

    /**
     * 主键
     */
    @CheckNotNull(message = "非法ID", groups = UpdGroup.class)
    @CheckIsNullOrEmpty(message = "无效ID", groups = AddGroup.class)
    @TableId
    private String id;
    /**
     * 知识库id
     * @see OpsKnowledge#getId()
     */
    @CheckNotNull(message = "请选择知识库")
    private String knowledgeId;
    /**
     * 评论
     */
    @CheckLength(min = 1, max = 1000, message = "评论超过长度限制")
    @CheckNotNull(message = "请输入评论")
    private String comment;

}
